﻿<%@ Control Language="VB" AutoEventWireup="false" CodeFile="AddPerson.ascx.vb" Inherits="WebForm_ManageVolunteer_AddPerson" %>
<%@ Register Src="~/WebForm/CommonControl/CalendarTextBox.ascx" TagName="CalendarTextBox"
    TagPrefix="My" %>  
<%--<asp:Panel ID="panel1" runat="server" BackColor="white" BorderWidth="1" SkinID="DragPanel"
    Width="400">
    <br />
    <div align="center">
        <asp:Label ID="lblForm" runat="server" meta:resourcekey="Page" SkinID="title" ForeColor="#408080"></asp:Label>
    </div>
    <br />--%>
<asp:FormView ID="fv" runat="server" DefaultMode="Insert">
    <ItemTemplate>
        <table>
            <tr>
                <td align="right">
                    <asp:Label ID="lblPersonID" runat="server" meta:resourcekey="lblPersonID"></asp:Label>
                </td>
                <td align="left">
                    <asp:TextBox ID="txtPersonID" runat="server" Text='<%#Bind("PersonID") %>'></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblPersonName" runat="server" meta:resourcekey="lblPersonName"></asp:Label>
                </td>
                <td align="left">
                    <asp:TextBox ID="txtPersonName" runat="server" Text='<%#Bind("PersonName") %>'></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblIdentificationID" runat="server" meta:resourcekey="lblIdentificationID"></asp:Label>
                </td>
                <td align="left">
                    <asp:TextBox ID="txtIdentificationID" MaxLength="10" runat="server" Text='<%# Bind("IdentificationID") %>'></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblGender" runat="server" meta:resourcekey="lblGender"></asp:Label>
                </td>
                <td align="left">
                    <asp:DropDownList ID="ddlGender" runat="server" ></asp:DropDownList>  
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblBirthDay" runat="server" meta:resourcekey="lblBirthDay"></asp:Label>
                </td>
                <td align="left">
                    <My:CalendarTextBox ID="txtBirthday" runat="server" MinYear="1912" Text='<%#Bind("Birthday") %>' />
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblOccupationType" runat="server" meta:resourcekey="lblOccupationType"></asp:Label>
                </td>
                <td align="left">
                    <asp:DropDownList ID="ddlOccupationType" runat="server" ></asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblEducationLevel" runat="server" meta:resourcekey="lblEducationLevel"></asp:Label>
                </td>
                <td align="left">
                    <asp:DropDownList ID="ddlEducationLevel" runat="server"></asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblEmail" runat="server" meta:resourcekey="lblEmail"></asp:Label>
                </td>
                <td align="left">
                    <asp:TextBox ID="txtEmail" runat="server" Text='<%# Bind("Email") %>'></asp:TextBox>
                </td>
                    <td><asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ErrorMessage="RegularExpressionValidator" ControlToValidate="txtEmail" ValidationExpression="^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$">請輸入正確E-mail!</asp:RegularExpressionValidator></td></tr>
            
            <tr>
               <td align ="right">
                        <asp:Label ID="lblPhoneNumber" runat="server" Text="<%$ Resources:PhoneNumber %>"></asp:Label>
                    </td>
                    <td align ="left">
                        <asp:TextBox ID="txtPhoneNumber" runat="server" MaxLength="50" Text='<%# Bind("PhoneNumber") %>'></asp:TextBox>
                    </td>
            </tr>
                            <tr>
                    <td align="right">
                        <asp:Label ID="lblFaxPhoneNumber" runat="server" Text="<%$ Resources:FaxPhoneNumber %>"></asp:Label>
                    </td>
                    <td align="left">
                        <asp:TextBox ID="txtFaxPhoneNumber" runat="server" MaxLength="50" Text='<%# Bind("FaxPhoneNumber") %>'></asp:TextBox>
                    </td>
                           </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblVOrganizationName" runat="server" meta:resourcekey="lblVOrganizationName"></asp:Label>
                </td>
                <td align="left">
                    <%--<asp:Label ID="txtVOrganizationName" runat="server" Text='<%#Bind("VOrganizationName") %>'></asp:Label>--%>
                    <asp:DropDownList ID="ddlPOrganizationID" runat="server"></asp:DropDownList>
                    <asp:RequiredFieldValidator ID="rfvPOrganizationID" runat="server" ControlToValidate="ddlPOrganizationID" Display="None" meta:resourcekey="rfvPOrganizationID" ValidationGroup="vInsert"></asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblPassword" runat="server" meta:resourcekey="lblPassword"></asp:Label>
                </td>
                <td align="left">
                    <asp:TextBox ID="txtPassword" runat="server" TextMode="Password"></asp:TextBox>
                </td>
            </tr>
            
            <tr>
                <td align="right">
                    <asp:Label ID="lblActive" runat="server" meta:resourcekey="lblActive"></asp:Label>
                </td>
                <td align="left">
                    <asp:DropDownList ID="ddlActive" runat="server" Enabled="true">
                    </asp:DropDownList>
                </td>
            </tr>
                        <tr>
                <td align="right">
                    <asp:Label ID="lblAdmin" runat="server" meta:resourcekey="lblAdmin"></asp:Label>
                </td>
                <td align="left">
                     <asp:DropDownList ID="ddlAdmin" runat="server">
                    </asp:DropDownList>
                </td>
            </tr>
        </table>
        <table>
            <tr>
                <td align="right">
                </td>
                <td align="left">
                    <asp:Button ID="btnAdd" runat="server" meta:resourcekey="btnAdd" CommandName="btnSave" ValidationGroup="vInsert" />
                    <ajaxToolkit:ConfirmButtonExtender ID="cbSave" runat="server" TargetControlID="btnAdd" meta:resourcekey="cbSave"></ajaxToolkit:ConfirmButtonExtender>
                    <asp:Button ID="btnOK" runat="server" Text="取消" />
                </td>
            </tr>
        </table>
        <asp:ValidationSummary ID="ValidationSummary1" runat="server" ShowMessageBox="True"
            ShowSummary="false" ValidationGroup="vInsert" />        
    </ItemTemplate>
</asp:FormView>
<br />
<%--</asp:Panel>
<asp:Button ID="btnDummy" runat="server" Style="display: none" SkinID="null" />
<ajaxToolkit:ModalPopupExtender ID="mpSearch" runat="server" TargetControlID="btnDummy"
    PopupControlID="panel1" OkControlID="btnOK" PopupDragHandleControlID="panel1" />
--%>
